package common.util {
	import mx.collections.ArrayCollection;

	public class ColorUtil {
		private static var colors : Array = [
			0Xb7dcf8,0Xf6c11f,0X90bd0d,0Xff9f63,0X259e9e,
			0Xd95555,0X965396,0X648e36,0Xbfb729,0X0991d7,
			0Xd63136,0Xa991c4,0X2cb287,0X7194ce,0Xf6b5a7,
			0Xb8b9b6,0X612b53,0X8f3f2b
		];
		
		public static function getColor(i:int=0):uint{
			while(i>=colors.length) i = i-colors.length;
			return colors[i];
		}
		
		//颜色转字符串
		public static function colorUintToStr(value:uint):String{
			return "0x"+value.toString(16);
		}
		
		//字符串转颜色
		public static function colorStrToUint(value:String):uint{
			return uint(value)
		}
	}
}